<?php
/**
 * Created by JetBrains PhpStorm.
 * User: Administrator
 * Date: 13-11-8
 * Time: 下午1:59
 */
use \pft\Member\MemberAccount as Mem;
if($_SESSION['dtype']!=9) {
    exit("不合法的身份访问！");
}
include '../common/autoload.php';
$mem = new Mem($GLOBALS['le']);

$id = intval($_GET['id']);
$type = intval($_GET['type']);
$tl = array('供应商', '分销商', '资源方','供应商');

$title = '【'.urldecode($_GET['t']) .'】的' . $tl[$type];
$relation_list = $mem->gemMemRShip($id, $type);

//foreach($relation_list as $list) {
//    $ret2 = $mem->createRelationship(268 , $list['son_id'], 0, 1);
//    print_r($ret2);
//}
//exit;

$LSIT = array('分销商','资源方','员工','供应商');
//0分销商1资源方2员工3供应商
$LST = array('供销关系','从属关系','平级关系','推荐关系');
$LS = array('正常','<font color="red">断连</font>');
$LD = array('供应商','分销商','资源方',5=>'普通会员',6=>'员工',7=>'集团');
include 'relations.tpl';